package Core;

public enum Rank {
	GUEST(0), MEMBER(1),MODERATOR(2),FORUMADMIN(3),SUPERADMIN(4);
	private int value;
	private Rank(int i)
	{
		value = i;
	}
	public int getValue()
	{
		return value;
	}
	public static Rank create(int rank)
	{
		if(rank == 0) return GUEST;
		if(rank == 1) return MEMBER;
		if(rank == 2) return MODERATOR;
		if(rank == 3) return FORUMADMIN;
		if(rank == 4) return SUPERADMIN;
		return GUEST;
	}
	public String toString()
	{
		if(this == GUEST) return "Guest";
		else if(this == MEMBER) return "Member";
		else if(this == MODERATOR) return "Moderator";
		else if(this == FORUMADMIN) return "Admin";
		else if(this == SUPERADMIN) return "SuperAdmin";
		else return "Hacker";
	}
}
